
import java.util.Timer;
import javax.microedition.lcdui.Command;
import javax.microedition.lcdui.CommandListener;
import javax.microedition.lcdui.Display;
import javax.microedition.lcdui.Displayable;
import javax.microedition.lcdui.Graphics;
import javax.microedition.lcdui.Image;
import javax.microedition.lcdui.StringItem;
import javax.microedition.lcdui.game.GameCanvas;

/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */

/**
 *
 * @author FFK
 */
public class Hightscoredetail extends GameCanvas implements CommandListener {

    
       private int aInt;
       private Command back ;
       public  Display d;
       public String[] sc = new String[10];
       public String score ="0";
       public StringItem item;
       public StringItem[] it = new StringItem[10];
       public Menu menu;
       private Image hs;
       private Graphics g;
       private Timer mTimer;
       private Number num;
       public Hightscoredetail(Display dp, Menu mn) {
            super(false);
            num = new Number();
            try{
            ImageLoader loader = ImageLoader.getInstance();
            hs=loader.loadImage("/bangvang.png");
            num.loadGraphics(loader.loadImage("/numbers.png"));
            }catch(Exception e){
                
            }
            
            back = new Command("OK", Command.BACK , 1);
            d = dp;
            
            g = getGraphics();
            this.addCommand(back);
            menu = mn;
            this.setCommandListener(this);
           
        
    }
    public void showhightscore(){
        d.setCurrent(this);
        repaint();
    }
    public void commandAction(Command cmnd, Displayable dsplbl) {
        if(cmnd == back) {
           d.setCurrent(menu);
        }
    }
      public void showNotify() {

      }
    public void hideNotify() {}
    
    public void render(Graphics g){
        
    }
    public void paint(Graphics g){
        int anchor = g.TOP | g.LEFT;
        g.setColor(0xFFFFFF);
        g.fillRect(0, 0, getWidth(), getHeight());
        g.drawImage(hs, 0, 0, anchor);
        num.Render(g);
    }

}
